//
//  YCHeader.m
//  LOLBox
//
//  Created by bb on 15-3-29.
//  Copyright (c) 2015年 Honey. All rights reserved.
//

#import "YCHeader.h"

@interface YCHeader ()
{
    //UILabel *_title;
}
@property (weak, nonatomic) IBOutlet UILabel *title;


@end

@implementation YCHeader

- (id)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        
        // Initialization code
        self.backgroundColor = [UIColor lightGrayColor];
        //self.frame = CGRectMake(0, 0, 320, 20);
        //_title = [[UILabel alloc] initWithFrame:self.frame];
        _title.textColor = [UIColor blackColor];
        _title.font = [UIFont systemFontOfSize:12];
        _title.backgroundColor = [UIColor greenColor];
        
        //[self addSubview:_title];
    }
    return self;
}

- (void)initTitle:(NSString *)name
{
    //NSLog(@"1");
    _title.text = [NSString stringWithFormat:@" %@",name];
}

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect
{
    // Drawing code
}
*/

@end
